Dr. Dobb's is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.


Welcome Guest | Log In | Register | Benefits
Channels ▼
RSS

Web Development

YUI Compressor 1.0 Released


Yahoo has released YUI Compressor 1.0, a JavaScript compressor that minifies the size of JavaScript files and obfuscates local variables by replacing them with single characters. The compression tool runs in Java, requiring Java 1.4 or later, and promises better compression over similar tools such as JSMin or the Dojo compressor. Download the YUI Compressor zip file: yuicompressor-1.0.zip

The YUI Compressor documentation states that obfuscation is safe, even when using constructs such as 'eval' or 'with' (although the compression is not optimal in those cases). The improved compression comes at the cost of time: the YUI Compressor is slower than other compression tools, and unlike JSMin, cannot be used for on-the-fly code minification. The YUI Compressor was written by Julien Lecomte, an engineer on Yahoo's DHTML Evangelist team. Julien has also written other JavaScript tools at Yahoo, such as the YUI-based Image Cropper Widget.

Last month, Yahoo's Exceptional Performance team released the YSlow perf tool, which analyzes web sites on 13 points and gives a letter grade for page performance. YSlow also gives advice for each point on how to improve your site.


Related Reading


More Insights